import request from '@/utils/request'

// 查询质量问题计数列表  发泡蜡
export function listDefective(query) {
  return request({
    url: '/system/defective/list',
    method: 'get',
    params: query
  })
}
// 查询质量问题计数列表  tesla
export function TlistDefective(query) {
  return request({
    url: '/system/tesladefective/list',
    method: 'get',
    params: query
  })
}

// 查询质量问题计数详细
export function getDefective(id) {
  return request({
    url: '/system/defective/' + id,
    method: 'get'
  })
}

// 新增质量问题计数
export function addDefective(data) {
  return request({
    url: '/system/defective',
    method: 'post',
    data: data
  })
}

// 修改质量问题计数
export function updateDefective(data) {
  return request({
    url: '/system/defective',
    method: 'put',
    data: data
  })
}

// 删除质量问题计数
export function delDefective(id) {
  return request({
    url: '/system/defective/' + id,
    method: 'delete'
  })
}

// 发泡质量统计导出
export function exDefectivefpl(pageNum,pageSize) {
  return request({
    url: '/system/defective/export',
    method: 'post',
    data:{pageNum,pageSize}
  })
}